package com.fadadianqi.mall.product.service;

import com.fadadianqi.logistics.admin.net.SpringUtils;
import org.springframework.context.MessageSource;

import java.util.Locale;

/**
 * Created by aroot on 2/12/14.
 */
public class AttrException extends Exception {

    public AttrException(){
        super();
    }

    public AttrException(String e) {
        super(e);
    }

    public String toString() {
        MessageSource ms = (MessageSource) SpringUtils.getBean("messageSource");
        return ms.getMessage(getMessage(), null, Locale.getDefault());
    }
}
